<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>列表页</title>
    <link href="../bootstrap/css/bootstrap.min.css" rel="stylesheet">
    <script src="../angular/angular.js"></script>
    <script src="../js/list.js"></script>
</head>
<body ng-app="myApp">
    <div ng-controller="listController" class="container">
        <div class="table-responsive">
            <table class="table table-bordered">
                <thead>
                    <tr>
                    <th>#</th>
                    <th>编号</th>
                    <th>用户名</th>
                    <th>昵称</th>
                    <th>状态</th>
                    <th>操作</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="user in users">
                    <th scope="row">
                        <input type="checkbox">
                    </th>
                    <td ng-bind="$index + 1"></td>
                    <td ng-bind="user.username"></td>
                    <td ng-bind="user.nickname"></td>
                    <td ng-switch="user.enable">
                        <span ng-switch-when="1">
                            启用
                        </span>
                        <span ng-switch-when="2">
                            禁用
                        </span>
                    </td>
                    <td>
                        <input class="btn btn-danger" type="button" value="删除">
                        <input class="btn btn-info" type="button" value="变更">
                    </td>
                    </tr>
                </tbody>
            </table>
        </div>
    </div>

</body>
</html>